using System.Linq;
using System.Text;
using System.Diagnostics;
using System.Runtime.Serialization;
using System.Collections;
using System.Data;
using System.ComponentModel;
using System.Data.OracleClient;
using WPFExcelReport.Helpers;
using WPFExcelReport.Controls;
namespace WPFExcelReport
{
    public partial class VAPNOMA
    {
        public DataRow Convert2APNOMA(DataRow dwInput, string ITXDBVERSION, bool IsConvert = false)
        {
            DataSet SResult = new DataSet();
            SResult = QueryAPNOMA(dwInput, 0);
            DataRow dwReturn = null;
            if (SResult.Tables[0].Rows.Count > 0)
            {
                dwReturn = SResult.Tables[0].Rows[0];
            }
            else
            {
                dwReturn = SResult.Tables[0].NewRow();
            }
            switch (ITXDBVERSION)
            {
                case "YGR":
                    #region=========
         dwReturn["APNMANDANT"] = " ".PadRight(2 ); 
         dwReturn["APNKSTKRS"] = " ".PadRight(2 ); 
         dwReturn["APNKST"] = " ".PadRight(4 ); 
         dwReturn["APNMTYP"] = " ".PadRight(8 ); 
         dwReturn["APNLINE"] = " ".PadRight(3 ); 
         dwReturn["APNAGANG"] = " ".PadRight(15 ); 
         dwReturn["APNUTHOURS"] = " ".PadRight(8 ); 
         dwReturn["APNAENZL"] = " ".PadRight(0 ); 
         dwReturn["APNAENB"] = " ".PadRight(8 ); 
         dwReturn["APNAEND"] = " ".PadRight(0 ); 
         dwReturn["APNNEUB"] = " ".PadRight(8 ); 
         dwReturn["APNNEUD"] = " ".PadRight(0 ); 
         dwReturn["APNFNOMA"] = " ".PadRight(0 ); 
         dwReturn["APNROUND"] = " ".PadRight(2 ); 
         dwReturn["APNLTIME"] = " ".PadRight(4 ); 
         dwReturn["APNBASED"] = " ".PadRight(2 ); 
         dwReturn["APNMACHMIN"] = " ".PadRight(2 ); 
         dwReturn["APNMACHMAX"] = " ".PadRight(2 ); 
         dwReturn["APNBALANCED"] = " ".PadRight(1 ); 
         dwReturn["APNLTIMEB1"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA1"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB2"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA2"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB3"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA3"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB4"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA4"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB5"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA5"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB6"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA6"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB7"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA7"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB8"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA8"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB9"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA9"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB10"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA10"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB11"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA11"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB12"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA12"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB13"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA13"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB14"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA14"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB15"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA15"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB16"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA16"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB17"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA17"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB18"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA18"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB19"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA19"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB20"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA20"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB21"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA21"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB22"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA22"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB23"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA23"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB24"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA24"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB25"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA25"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB26"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA26"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB27"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA27"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB28"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA28"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB29"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA29"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB30"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA30"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB31"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA31"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB32"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA32"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB33"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA33"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB34"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA34"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB35"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA35"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB36"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA36"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB37"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA37"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB38"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA38"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB39"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA39"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB40"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA40"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB41"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA41"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB42"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA42"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB43"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA43"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB44"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA44"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB45"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA45"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB46"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA46"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB47"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA47"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB48"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA48"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB49"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA49"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB50"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA50"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB51"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA51"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB52"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA52"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB53"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA53"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB54"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA54"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB55"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA55"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB56"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA56"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB57"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA57"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB58"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA58"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB59"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA59"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB60"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA60"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB61"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA61"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB62"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA62"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB63"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA63"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB64"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA64"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB65"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA65"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB66"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA66"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB67"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA67"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB68"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA68"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB69"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA69"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB70"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA70"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB71"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA71"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB72"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA72"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB73"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA73"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB74"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA74"] = " ".PadRight(0 ); 
         dwReturn["APNLTIMEB75"] = " ".PadRight(4 ); 
         dwReturn["APNBNOMA75"] = " ".PadRight(0 ); 
         dwReturn["APNFILLER"] = " ".PadRight(67 ); 
                    #endregion
                    break;
                case "JLT":

                    break;
                default:

                    break;
            }
            if (IsConvert)
            {
                foreach (DataColumn cm in dwInput.Table.Columns)
                {
                    if (dwInput[cm.ColumnName].ToString() == "")
                        continue;
                    if (dwReturn.Table.Columns.Contains(cm.ColumnName))
                    {
                        dwReturn[cm.ColumnName] = dwInput[cm.ColumnName];
                    }
                }
            }
            return dwReturn;
        }
        public void MapAPNOMA(ref DataRow dwLocal, DataRow dwData)
        {
            BlindMap(ref dwLocal, dwData);
        }
        public void SaveAPNOMA(DataRow dwData, string ITXDBVERSION = "50.24")
        {
            DataSet setResult = new DataSet();
            DataTable tbLocal = null;
            DataRow dwLocal = null;
            bool flgExist = false;
            setResult = QueryAPNOMA(dwData);
            if (setResult.Tables.Count > 0)
            {
                tbLocal = setResult.Tables[0];
                if (tbLocal.Rows.Count > 0)
                {
                    flgExist = true;
                    dwLocal = tbLocal.Rows[0];
                }
                else
                {
                    dwLocal = tbLocal.NewRow();
                }
            }
            MapAPNOMA(ref dwLocal, dwData);

            if (!flgExist)
            {

                InsertAPNOMA(dwLocal, ITXDBVERSION);
            }
            UpdateAPNOMA(dwLocal);
        }
        public void InsertAPNOMA(DataRow dwData, string ITXDBVERSION = "50.24")
        {
            OracleCommand or1;
            or1 = OracleDB.CreateCommand();
            switch (ITXDBVERSION)
            {
                case "YGR":
                    or1.CommandText = "INSERT INTO APNOMA(VAKBMANDANT, VAKBKOLL, VAKBART, VAKBKUNDNR, VAKBFARBE, VAKBKDARTNR, VAKBKDARTBEZ, VAKBKDFARBNR, VAKBANDRUCK, VAKBMEGEW, VAKBMENGEH, VAKBGEWVON, VAKBGEWBIS, VAKBGEWCA, VAKBGEWFKT, VAKBGEWGRP, VAKBMEGFKT, VAKBMEGGRP, VAKBAENDZL, VAKBAENDBEN, VAKBAENDDAT, VAKBNEUBEN, VAKBNEUDAT, VAKBFILLER)"
                        + " VALUES (:VAKBMANDANT, :VAKBKOLL, :VAKBART, :VAKBKUNDNR, :VAKBFARBE, '                         ', '                         ', '                             ', ' ', '   ', '   ', 0, 0, ' ', '000000000000', ' ', '000000000000', ' ', 0, '        ', '000000', '        ', '      ', '                                          ')";
                    or1.Parameters.Add("VAKBMANDANT", OracleType.NVarChar).Value = dwData["VAKBMANDANT"].ToString();
                    or1.Parameters.Add("VAKBKOLL", OracleType.NVarChar).Value = dwData["VAKBKOLL"].ToString();
                    or1.Parameters.Add("VAKBART", OracleType.NVarChar).Value = dwData["VAKBART"].ToString();
                    or1.Parameters.Add("VAKBFARBE", OracleType.NVarChar).Value = dwData["VAKBFARBE"].ToString();
                    or1.Parameters.Add("VAKBKUNDNR", OracleType.NVarChar).Value = dwData["VAKBKUNDNR"].ToString();
                    break;
                //VAFMANDANT VAFKOLL VAFART VAFFARBE VAFBEZ VAFFFARBE

            }
            
            Connect2Proxy(or1);
        }
        public DataSet QueryAPNOMA(DataRow dwData, int option = 1)
        {
            DataSet Return;
            DataSet Result = new DataSet();
            OracleCommand or1 = OracleDB.CreateCommand();
            switch (option)
            {
                case 0:
                    or1.CommandText = "SELECT * FROM APNOMA WHERE  ROWNUM<2 ";
                    break;
              
                case 99:
                    or1.CommandText = "SELECT * FROM APNOMA  WHERE ROWNUM<50";
                    break;
                default:
                    break;
            }
            Result = Connect2Proxy(or1);
            if (Result.Tables.Count > 0)
                Result.Tables[0].TableName = "APNOMA";
            Return = Result;
            return Return;
        }
        public void DeleteAPNOMA(DataRow dwData, int option = 1)
        {

            OracleCommand or1 = OracleDB.CreateCommand();
            switch (option)
            {
                case 1:
                    or1.CommandText = "DELETE FROM APNOMA   WHERE  VAKBMANDANT=:VAKBMANDANT AND VAKBKOLL=:VAKBKOLL AND VAKBART =:VAKBART AND VAKBFARBE=:VAKBFARBE AND VAKBKUNDNR=:VAKBKUNDNR";
                     or1.Parameters.Add("VAKBMANDANT", OracleType.NVarChar).Value = dwData["VAKBMANDANT"].ToString();
                    or1.Parameters.Add("VAKBKOLL", OracleType.NVarChar).Value = dwData["VAKBKOLL"].ToString();
                    or1.Parameters.Add("VAKBART", OracleType.NVarChar).Value = dwData["VAKBART"].ToString();
                    or1.Parameters.Add("VAKBFARBE", OracleType.NVarChar).Value = dwData["VAKBFARBE"].ToString();
                    or1.Parameters.Add("VAKBKUNDNR", OracleType.NVarChar).Value = dwData["VAKBKUNDNR"].ToString();
                    break;
                default:
                    break;
            }
            Connect2Proxy(or1);
        } 
      
        public void UpdateAPNOMA(DataRow dwData, string ITXDBVERSION = "50.24", int option = 1)
        {
            OracleCommand or1;
            DataSet Result = new DataSet();
            or1 = OracleDB.CreateCommand();
            switch (option)
            {
                case 1:
                    #region====Command==== 
                    or1.CommandText = "UPDATE APNOMA SET "
                    +"APNMANDANT= :APNMANDANT,"
                    +"APNKSTKRS= :APNKSTKRS,"
                    +"APNKST= :APNKST,"
                    +"APNMTYP= :APNMTYP,"
                    +"APNLINE= :APNLINE,"
                    +"APNAGANG= :APNAGANG,"
                    +"APNUTHOURS= :APNUTHOURS,"
                    +"APNAENZL= :APNAENZL,"
                    +"APNAENB= :APNAENB,"
                    +"APNAEND= :APNAEND,"
                    +"APNNEUB= :APNNEUB,"
                    +"APNNEUD= :APNNEUD,"
                    +"APNFNOMA= :APNFNOMA,"
                    +"APNROUND= :APNROUND,"
                    +"APNLTIME= :APNLTIME,"
                    +"APNBASED= :APNBASED,"
                    +"APNMACHMIN= :APNMACHMIN,"
                    +"APNMACHMAX= :APNMACHMAX,"
                    +"APNBALANCED= :APNBALANCED,"
                    +"APNLTIMEB1= :APNLTIMEB1,"
                    +"APNBNOMA1= :APNBNOMA1,"
                    +"APNLTIMEB2= :APNLTIMEB2,"
                    +"APNBNOMA2= :APNBNOMA2,"
                    +"APNLTIMEB3= :APNLTIMEB3,"
                    +"APNBNOMA3= :APNBNOMA3,"
                    +"APNLTIMEB4= :APNLTIMEB4,"
                    +"APNBNOMA4= :APNBNOMA4,"
                    +"APNLTIMEB5= :APNLTIMEB5,"
                    +"APNBNOMA5= :APNBNOMA5,"
                    +"APNLTIMEB6= :APNLTIMEB6,"
                    +"APNBNOMA6= :APNBNOMA6,"
                    +"APNLTIMEB7= :APNLTIMEB7,"
                    +"APNBNOMA7= :APNBNOMA7,"
                    +"APNLTIMEB8= :APNLTIMEB8,"
                    +"APNBNOMA8= :APNBNOMA8,"
                    +"APNLTIMEB9= :APNLTIMEB9,"
                    +"APNBNOMA9= :APNBNOMA9,"
                    +"APNLTIMEB10= :APNLTIMEB10,"
                    +"APNBNOMA10= :APNBNOMA10,"
                    +"APNLTIMEB11= :APNLTIMEB11,"
                    +"APNBNOMA11= :APNBNOMA11,"
                    +"APNLTIMEB12= :APNLTIMEB12,"
                    +"APNBNOMA12= :APNBNOMA12,"
                    +"APNLTIMEB13= :APNLTIMEB13,"
                    +"APNBNOMA13= :APNBNOMA13,"
                    +"APNLTIMEB14= :APNLTIMEB14,"
                    +"APNBNOMA14= :APNBNOMA14,"
                    +"APNLTIMEB15= :APNLTIMEB15,"
                    +"APNBNOMA15= :APNBNOMA15,"
                    +"APNLTIMEB16= :APNLTIMEB16,"
                    +"APNBNOMA16= :APNBNOMA16,"
                    +"APNLTIMEB17= :APNLTIMEB17,"
                    +"APNBNOMA17= :APNBNOMA17,"
                    +"APNLTIMEB18= :APNLTIMEB18,"
                    +"APNBNOMA18= :APNBNOMA18,"
                    +"APNLTIMEB19= :APNLTIMEB19,"
                    +"APNBNOMA19= :APNBNOMA19,"
                    +"APNLTIMEB20= :APNLTIMEB20,"
                    +"APNBNOMA20= :APNBNOMA20,"
                    +"APNLTIMEB21= :APNLTIMEB21,"
                    +"APNBNOMA21= :APNBNOMA21,"
                    +"APNLTIMEB22= :APNLTIMEB22,"
                    +"APNBNOMA22= :APNBNOMA22,"
                    +"APNLTIMEB23= :APNLTIMEB23,"
                    +"APNBNOMA23= :APNBNOMA23,"
                    +"APNLTIMEB24= :APNLTIMEB24,"
                    +"APNBNOMA24= :APNBNOMA24,"
                    +"APNLTIMEB25= :APNLTIMEB25,"
                    +"APNBNOMA25= :APNBNOMA25,"
                    +"APNLTIMEB26= :APNLTIMEB26,"
                    +"APNBNOMA26= :APNBNOMA26,"
                    +"APNLTIMEB27= :APNLTIMEB27,"
                    +"APNBNOMA27= :APNBNOMA27,"
                    +"APNLTIMEB28= :APNLTIMEB28,"
                    +"APNBNOMA28= :APNBNOMA28,"
                    +"APNLTIMEB29= :APNLTIMEB29,"
                    +"APNBNOMA29= :APNBNOMA29,"
                    +"APNLTIMEB30= :APNLTIMEB30,"
                    +"APNBNOMA30= :APNBNOMA30,"
                    +"APNLTIMEB31= :APNLTIMEB31,"
                    +"APNBNOMA31= :APNBNOMA31,"
                    +"APNLTIMEB32= :APNLTIMEB32,"
                    +"APNBNOMA32= :APNBNOMA32,"
                    +"APNLTIMEB33= :APNLTIMEB33,"
                    +"APNBNOMA33= :APNBNOMA33,"
                    +"APNLTIMEB34= :APNLTIMEB34,"
                    +"APNBNOMA34= :APNBNOMA34,"
                    +"APNLTIMEB35= :APNLTIMEB35,"
                    +"APNBNOMA35= :APNBNOMA35,"
                    +"APNLTIMEB36= :APNLTIMEB36,"
                    +"APNBNOMA36= :APNBNOMA36,"
                    +"APNLTIMEB37= :APNLTIMEB37,"
                    +"APNBNOMA37= :APNBNOMA37,"
                    +"APNLTIMEB38= :APNLTIMEB38,"
                    +"APNBNOMA38= :APNBNOMA38,"
                    +"APNLTIMEB39= :APNLTIMEB39,"
                    +"APNBNOMA39= :APNBNOMA39,"
                    +"APNLTIMEB40= :APNLTIMEB40,"
                    +"APNBNOMA40= :APNBNOMA40,"
                    +"APNLTIMEB41= :APNLTIMEB41,"
                    +"APNBNOMA41= :APNBNOMA41,"
                    +"APNLTIMEB42= :APNLTIMEB42,"
                    +"APNBNOMA42= :APNBNOMA42,"
                    +"APNLTIMEB43= :APNLTIMEB43,"
                    +"APNBNOMA43= :APNBNOMA43,"
                    +"APNLTIMEB44= :APNLTIMEB44,"
                    +"APNBNOMA44= :APNBNOMA44,"
                    +"APNLTIMEB45= :APNLTIMEB45,"
                    +"APNBNOMA45= :APNBNOMA45,"
                    +"APNLTIMEB46= :APNLTIMEB46,"
                    +"APNBNOMA46= :APNBNOMA46,"
                    +"APNLTIMEB47= :APNLTIMEB47,"
                    +"APNBNOMA47= :APNBNOMA47,"
                    +"APNLTIMEB48= :APNLTIMEB48,"
                    +"APNBNOMA48= :APNBNOMA48,"
                    +"APNLTIMEB49= :APNLTIMEB49,"
                    +"APNBNOMA49= :APNBNOMA49,"
                    +"APNLTIMEB50= :APNLTIMEB50,"
                    +"APNBNOMA50= :APNBNOMA50,"
                    +"APNLTIMEB51= :APNLTIMEB51,"
                    +"APNBNOMA51= :APNBNOMA51,"
                    +"APNLTIMEB52= :APNLTIMEB52,"
                    +"APNBNOMA52= :APNBNOMA52,"
                    +"APNLTIMEB53= :APNLTIMEB53,"
                    +"APNBNOMA53= :APNBNOMA53,"
                    +"APNLTIMEB54= :APNLTIMEB54,"
                    +"APNBNOMA54= :APNBNOMA54,"
                    +"APNLTIMEB55= :APNLTIMEB55,"
                    +"APNBNOMA55= :APNBNOMA55,"
                    +"APNLTIMEB56= :APNLTIMEB56,"
                    +"APNBNOMA56= :APNBNOMA56,"
                    +"APNLTIMEB57= :APNLTIMEB57,"
                    +"APNBNOMA57= :APNBNOMA57,"
                    +"APNLTIMEB58= :APNLTIMEB58,"
                    +"APNBNOMA58= :APNBNOMA58,"
                    +"APNLTIMEB59= :APNLTIMEB59,"
                    +"APNBNOMA59= :APNBNOMA59,"
                    +"APNLTIMEB60= :APNLTIMEB60,"
                    +"APNBNOMA60= :APNBNOMA60,"
                    +"APNLTIMEB61= :APNLTIMEB61,"
                    +"APNBNOMA61= :APNBNOMA61,"
                    +"APNLTIMEB62= :APNLTIMEB62,"
                    +"APNBNOMA62= :APNBNOMA62,"
                    +"APNLTIMEB63= :APNLTIMEB63,"
                    +"APNBNOMA63= :APNBNOMA63,"
                    +"APNLTIMEB64= :APNLTIMEB64,"
                    +"APNBNOMA64= :APNBNOMA64,"
                    +"APNLTIMEB65= :APNLTIMEB65,"
                    +"APNBNOMA65= :APNBNOMA65,"
                    +"APNLTIMEB66= :APNLTIMEB66,"
                    +"APNBNOMA66= :APNBNOMA66,"
                    +"APNLTIMEB67= :APNLTIMEB67,"
                    +"APNBNOMA67= :APNBNOMA67,"
                    +"APNLTIMEB68= :APNLTIMEB68,"
                    +"APNBNOMA68= :APNBNOMA68,"
                    +"APNLTIMEB69= :APNLTIMEB69,"
                    +"APNBNOMA69= :APNBNOMA69,"
                    +"APNLTIMEB70= :APNLTIMEB70,"
                    +"APNBNOMA70= :APNBNOMA70,"
                    +"APNLTIMEB71= :APNLTIMEB71,"
                    +"APNBNOMA71= :APNBNOMA71,"
                    +"APNLTIMEB72= :APNLTIMEB72,"
                    +"APNBNOMA72= :APNBNOMA72,"
                    +"APNLTIMEB73= :APNLTIMEB73,"
                    +"APNBNOMA73= :APNBNOMA73,"
                    +"APNLTIMEB74= :APNLTIMEB74,"
                    +"APNBNOMA74= :APNBNOMA74,"
                    +"APNLTIMEB75= :APNLTIMEB75,"
                    +"APNBNOMA75= :APNBNOMA75,"
                    +"APNFILLER= :APNFILLER,"
                        + " WHERE  "
                        + "  VAKBMANDANT=:VAKBMANDANT AND VAKBKOLL=:VAKBKOLL AND VAKBART =:VAKBART AND VAKBFARBE=:VAKBFARBE AND VAKBKUNDNR=:VAKBKUNDNR";
                    #endregion

                    #region====Parameters====
          or1.Parameters.Add("APNMANDANT", OracleType.NVarChar).Value = dwData["APNMANDANT"].ToString(); 
          or1.Parameters.Add("APNKSTKRS", OracleType.NVarChar).Value = dwData["APNKSTKRS"].ToString(); 
          or1.Parameters.Add("APNKST", OracleType.NVarChar).Value = dwData["APNKST"].ToString(); 
          or1.Parameters.Add("APNMTYP", OracleType.NVarChar).Value = dwData["APNMTYP"].ToString(); 
          or1.Parameters.Add("APNLINE", OracleType.NVarChar).Value = dwData["APNLINE"].ToString(); 
          or1.Parameters.Add("APNAGANG", OracleType.NVarChar).Value = dwData["APNAGANG"].ToString(); 
          or1.Parameters.Add("APNUTHOURS", OracleType.NVarChar).Value = dwData["APNUTHOURS"].ToString(); 
          or1.Parameters.Add("APNAENZL", OracleType.NVarChar).Value = dwData["APNAENZL"].ToString(); 
          or1.Parameters.Add("APNAENB", OracleType.NVarChar).Value = dwData["APNAENB"].ToString(); 
          or1.Parameters.Add("APNAEND", OracleType.NVarChar).Value = dwData["APNAEND"].ToString(); 
          or1.Parameters.Add("APNNEUB", OracleType.NVarChar).Value = dwData["APNNEUB"].ToString(); 
          or1.Parameters.Add("APNNEUD", OracleType.NVarChar).Value = dwData["APNNEUD"].ToString(); 
          or1.Parameters.Add("APNFNOMA", OracleType.NVarChar).Value = dwData["APNFNOMA"].ToString(); 
          or1.Parameters.Add("APNROUND", OracleType.NVarChar).Value = dwData["APNROUND"].ToString(); 
          or1.Parameters.Add("APNLTIME", OracleType.NVarChar).Value = dwData["APNLTIME"].ToString(); 
          or1.Parameters.Add("APNBASED", OracleType.NVarChar).Value = dwData["APNBASED"].ToString(); 
          or1.Parameters.Add("APNMACHMIN", OracleType.NVarChar).Value = dwData["APNMACHMIN"].ToString(); 
          or1.Parameters.Add("APNMACHMAX", OracleType.NVarChar).Value = dwData["APNMACHMAX"].ToString(); 
          or1.Parameters.Add("APNBALANCED", OracleType.NVarChar).Value = dwData["APNBALANCED"].ToString(); 
          or1.Parameters.Add("APNLTIMEB1", OracleType.NVarChar).Value = dwData["APNLTIMEB1"].ToString(); 
          or1.Parameters.Add("APNBNOMA1", OracleType.NVarChar).Value = dwData["APNBNOMA1"].ToString(); 
          or1.Parameters.Add("APNLTIMEB2", OracleType.NVarChar).Value = dwData["APNLTIMEB2"].ToString(); 
          or1.Parameters.Add("APNBNOMA2", OracleType.NVarChar).Value = dwData["APNBNOMA2"].ToString(); 
          or1.Parameters.Add("APNLTIMEB3", OracleType.NVarChar).Value = dwData["APNLTIMEB3"].ToString(); 
          or1.Parameters.Add("APNBNOMA3", OracleType.NVarChar).Value = dwData["APNBNOMA3"].ToString(); 
          or1.Parameters.Add("APNLTIMEB4", OracleType.NVarChar).Value = dwData["APNLTIMEB4"].ToString(); 
          or1.Parameters.Add("APNBNOMA4", OracleType.NVarChar).Value = dwData["APNBNOMA4"].ToString(); 
          or1.Parameters.Add("APNLTIMEB5", OracleType.NVarChar).Value = dwData["APNLTIMEB5"].ToString(); 
          or1.Parameters.Add("APNBNOMA5", OracleType.NVarChar).Value = dwData["APNBNOMA5"].ToString(); 
          or1.Parameters.Add("APNLTIMEB6", OracleType.NVarChar).Value = dwData["APNLTIMEB6"].ToString(); 
          or1.Parameters.Add("APNBNOMA6", OracleType.NVarChar).Value = dwData["APNBNOMA6"].ToString(); 
          or1.Parameters.Add("APNLTIMEB7", OracleType.NVarChar).Value = dwData["APNLTIMEB7"].ToString(); 
          or1.Parameters.Add("APNBNOMA7", OracleType.NVarChar).Value = dwData["APNBNOMA7"].ToString(); 
          or1.Parameters.Add("APNLTIMEB8", OracleType.NVarChar).Value = dwData["APNLTIMEB8"].ToString(); 
          or1.Parameters.Add("APNBNOMA8", OracleType.NVarChar).Value = dwData["APNBNOMA8"].ToString(); 
          or1.Parameters.Add("APNLTIMEB9", OracleType.NVarChar).Value = dwData["APNLTIMEB9"].ToString(); 
          or1.Parameters.Add("APNBNOMA9", OracleType.NVarChar).Value = dwData["APNBNOMA9"].ToString(); 
          or1.Parameters.Add("APNLTIMEB10", OracleType.NVarChar).Value = dwData["APNLTIMEB10"].ToString(); 
          or1.Parameters.Add("APNBNOMA10", OracleType.NVarChar).Value = dwData["APNBNOMA10"].ToString(); 
          or1.Parameters.Add("APNLTIMEB11", OracleType.NVarChar).Value = dwData["APNLTIMEB11"].ToString(); 
          or1.Parameters.Add("APNBNOMA11", OracleType.NVarChar).Value = dwData["APNBNOMA11"].ToString(); 
          or1.Parameters.Add("APNLTIMEB12", OracleType.NVarChar).Value = dwData["APNLTIMEB12"].ToString(); 
          or1.Parameters.Add("APNBNOMA12", OracleType.NVarChar).Value = dwData["APNBNOMA12"].ToString(); 
          or1.Parameters.Add("APNLTIMEB13", OracleType.NVarChar).Value = dwData["APNLTIMEB13"].ToString(); 
          or1.Parameters.Add("APNBNOMA13", OracleType.NVarChar).Value = dwData["APNBNOMA13"].ToString(); 
          or1.Parameters.Add("APNLTIMEB14", OracleType.NVarChar).Value = dwData["APNLTIMEB14"].ToString(); 
          or1.Parameters.Add("APNBNOMA14", OracleType.NVarChar).Value = dwData["APNBNOMA14"].ToString(); 
          or1.Parameters.Add("APNLTIMEB15", OracleType.NVarChar).Value = dwData["APNLTIMEB15"].ToString(); 
          or1.Parameters.Add("APNBNOMA15", OracleType.NVarChar).Value = dwData["APNBNOMA15"].ToString(); 
          or1.Parameters.Add("APNLTIMEB16", OracleType.NVarChar).Value = dwData["APNLTIMEB16"].ToString(); 
          or1.Parameters.Add("APNBNOMA16", OracleType.NVarChar).Value = dwData["APNBNOMA16"].ToString(); 
          or1.Parameters.Add("APNLTIMEB17", OracleType.NVarChar).Value = dwData["APNLTIMEB17"].ToString(); 
          or1.Parameters.Add("APNBNOMA17", OracleType.NVarChar).Value = dwData["APNBNOMA17"].ToString(); 
          or1.Parameters.Add("APNLTIMEB18", OracleType.NVarChar).Value = dwData["APNLTIMEB18"].ToString(); 
          or1.Parameters.Add("APNBNOMA18", OracleType.NVarChar).Value = dwData["APNBNOMA18"].ToString(); 
          or1.Parameters.Add("APNLTIMEB19", OracleType.NVarChar).Value = dwData["APNLTIMEB19"].ToString(); 
          or1.Parameters.Add("APNBNOMA19", OracleType.NVarChar).Value = dwData["APNBNOMA19"].ToString(); 
          or1.Parameters.Add("APNLTIMEB20", OracleType.NVarChar).Value = dwData["APNLTIMEB20"].ToString(); 
          or1.Parameters.Add("APNBNOMA20", OracleType.NVarChar).Value = dwData["APNBNOMA20"].ToString(); 
          or1.Parameters.Add("APNLTIMEB21", OracleType.NVarChar).Value = dwData["APNLTIMEB21"].ToString(); 
          or1.Parameters.Add("APNBNOMA21", OracleType.NVarChar).Value = dwData["APNBNOMA21"].ToString(); 
          or1.Parameters.Add("APNLTIMEB22", OracleType.NVarChar).Value = dwData["APNLTIMEB22"].ToString(); 
          or1.Parameters.Add("APNBNOMA22", OracleType.NVarChar).Value = dwData["APNBNOMA22"].ToString(); 
          or1.Parameters.Add("APNLTIMEB23", OracleType.NVarChar).Value = dwData["APNLTIMEB23"].ToString(); 
          or1.Parameters.Add("APNBNOMA23", OracleType.NVarChar).Value = dwData["APNBNOMA23"].ToString(); 
          or1.Parameters.Add("APNLTIMEB24", OracleType.NVarChar).Value = dwData["APNLTIMEB24"].ToString(); 
          or1.Parameters.Add("APNBNOMA24", OracleType.NVarChar).Value = dwData["APNBNOMA24"].ToString(); 
          or1.Parameters.Add("APNLTIMEB25", OracleType.NVarChar).Value = dwData["APNLTIMEB25"].ToString(); 
          or1.Parameters.Add("APNBNOMA25", OracleType.NVarChar).Value = dwData["APNBNOMA25"].ToString(); 
          or1.Parameters.Add("APNLTIMEB26", OracleType.NVarChar).Value = dwData["APNLTIMEB26"].ToString(); 
          or1.Parameters.Add("APNBNOMA26", OracleType.NVarChar).Value = dwData["APNBNOMA26"].ToString(); 
          or1.Parameters.Add("APNLTIMEB27", OracleType.NVarChar).Value = dwData["APNLTIMEB27"].ToString(); 
          or1.Parameters.Add("APNBNOMA27", OracleType.NVarChar).Value = dwData["APNBNOMA27"].ToString(); 
          or1.Parameters.Add("APNLTIMEB28", OracleType.NVarChar).Value = dwData["APNLTIMEB28"].ToString(); 
          or1.Parameters.Add("APNBNOMA28", OracleType.NVarChar).Value = dwData["APNBNOMA28"].ToString(); 
          or1.Parameters.Add("APNLTIMEB29", OracleType.NVarChar).Value = dwData["APNLTIMEB29"].ToString(); 
          or1.Parameters.Add("APNBNOMA29", OracleType.NVarChar).Value = dwData["APNBNOMA29"].ToString(); 
          or1.Parameters.Add("APNLTIMEB30", OracleType.NVarChar).Value = dwData["APNLTIMEB30"].ToString(); 
          or1.Parameters.Add("APNBNOMA30", OracleType.NVarChar).Value = dwData["APNBNOMA30"].ToString(); 
          or1.Parameters.Add("APNLTIMEB31", OracleType.NVarChar).Value = dwData["APNLTIMEB31"].ToString(); 
          or1.Parameters.Add("APNBNOMA31", OracleType.NVarChar).Value = dwData["APNBNOMA31"].ToString(); 
          or1.Parameters.Add("APNLTIMEB32", OracleType.NVarChar).Value = dwData["APNLTIMEB32"].ToString(); 
          or1.Parameters.Add("APNBNOMA32", OracleType.NVarChar).Value = dwData["APNBNOMA32"].ToString(); 
          or1.Parameters.Add("APNLTIMEB33", OracleType.NVarChar).Value = dwData["APNLTIMEB33"].ToString(); 
          or1.Parameters.Add("APNBNOMA33", OracleType.NVarChar).Value = dwData["APNBNOMA33"].ToString(); 
          or1.Parameters.Add("APNLTIMEB34", OracleType.NVarChar).Value = dwData["APNLTIMEB34"].ToString(); 
          or1.Parameters.Add("APNBNOMA34", OracleType.NVarChar).Value = dwData["APNBNOMA34"].ToString(); 
          or1.Parameters.Add("APNLTIMEB35", OracleType.NVarChar).Value = dwData["APNLTIMEB35"].ToString(); 
          or1.Parameters.Add("APNBNOMA35", OracleType.NVarChar).Value = dwData["APNBNOMA35"].ToString(); 
          or1.Parameters.Add("APNLTIMEB36", OracleType.NVarChar).Value = dwData["APNLTIMEB36"].ToString(); 
          or1.Parameters.Add("APNBNOMA36", OracleType.NVarChar).Value = dwData["APNBNOMA36"].ToString(); 
          or1.Parameters.Add("APNLTIMEB37", OracleType.NVarChar).Value = dwData["APNLTIMEB37"].ToString(); 
          or1.Parameters.Add("APNBNOMA37", OracleType.NVarChar).Value = dwData["APNBNOMA37"].ToString(); 
          or1.Parameters.Add("APNLTIMEB38", OracleType.NVarChar).Value = dwData["APNLTIMEB38"].ToString(); 
          or1.Parameters.Add("APNBNOMA38", OracleType.NVarChar).Value = dwData["APNBNOMA38"].ToString(); 
          or1.Parameters.Add("APNLTIMEB39", OracleType.NVarChar).Value = dwData["APNLTIMEB39"].ToString(); 
          or1.Parameters.Add("APNBNOMA39", OracleType.NVarChar).Value = dwData["APNBNOMA39"].ToString(); 
          or1.Parameters.Add("APNLTIMEB40", OracleType.NVarChar).Value = dwData["APNLTIMEB40"].ToString(); 
          or1.Parameters.Add("APNBNOMA40", OracleType.NVarChar).Value = dwData["APNBNOMA40"].ToString(); 
          or1.Parameters.Add("APNLTIMEB41", OracleType.NVarChar).Value = dwData["APNLTIMEB41"].ToString(); 
          or1.Parameters.Add("APNBNOMA41", OracleType.NVarChar).Value = dwData["APNBNOMA41"].ToString(); 
          or1.Parameters.Add("APNLTIMEB42", OracleType.NVarChar).Value = dwData["APNLTIMEB42"].ToString(); 
          or1.Parameters.Add("APNBNOMA42", OracleType.NVarChar).Value = dwData["APNBNOMA42"].ToString(); 
          or1.Parameters.Add("APNLTIMEB43", OracleType.NVarChar).Value = dwData["APNLTIMEB43"].ToString(); 
          or1.Parameters.Add("APNBNOMA43", OracleType.NVarChar).Value = dwData["APNBNOMA43"].ToString(); 
          or1.Parameters.Add("APNLTIMEB44", OracleType.NVarChar).Value = dwData["APNLTIMEB44"].ToString(); 
          or1.Parameters.Add("APNBNOMA44", OracleType.NVarChar).Value = dwData["APNBNOMA44"].ToString(); 
          or1.Parameters.Add("APNLTIMEB45", OracleType.NVarChar).Value = dwData["APNLTIMEB45"].ToString(); 
          or1.Parameters.Add("APNBNOMA45", OracleType.NVarChar).Value = dwData["APNBNOMA45"].ToString(); 
          or1.Parameters.Add("APNLTIMEB46", OracleType.NVarChar).Value = dwData["APNLTIMEB46"].ToString(); 
          or1.Parameters.Add("APNBNOMA46", OracleType.NVarChar).Value = dwData["APNBNOMA46"].ToString(); 
          or1.Parameters.Add("APNLTIMEB47", OracleType.NVarChar).Value = dwData["APNLTIMEB47"].ToString(); 
          or1.Parameters.Add("APNBNOMA47", OracleType.NVarChar).Value = dwData["APNBNOMA47"].ToString(); 
          or1.Parameters.Add("APNLTIMEB48", OracleType.NVarChar).Value = dwData["APNLTIMEB48"].ToString(); 
          or1.Parameters.Add("APNBNOMA48", OracleType.NVarChar).Value = dwData["APNBNOMA48"].ToString(); 
          or1.Parameters.Add("APNLTIMEB49", OracleType.NVarChar).Value = dwData["APNLTIMEB49"].ToString(); 
          or1.Parameters.Add("APNBNOMA49", OracleType.NVarChar).Value = dwData["APNBNOMA49"].ToString(); 
          or1.Parameters.Add("APNLTIMEB50", OracleType.NVarChar).Value = dwData["APNLTIMEB50"].ToString(); 
          or1.Parameters.Add("APNBNOMA50", OracleType.NVarChar).Value = dwData["APNBNOMA50"].ToString(); 
          or1.Parameters.Add("APNLTIMEB51", OracleType.NVarChar).Value = dwData["APNLTIMEB51"].ToString(); 
          or1.Parameters.Add("APNBNOMA51", OracleType.NVarChar).Value = dwData["APNBNOMA51"].ToString(); 
          or1.Parameters.Add("APNLTIMEB52", OracleType.NVarChar).Value = dwData["APNLTIMEB52"].ToString(); 
          or1.Parameters.Add("APNBNOMA52", OracleType.NVarChar).Value = dwData["APNBNOMA52"].ToString(); 
          or1.Parameters.Add("APNLTIMEB53", OracleType.NVarChar).Value = dwData["APNLTIMEB53"].ToString(); 
          or1.Parameters.Add("APNBNOMA53", OracleType.NVarChar).Value = dwData["APNBNOMA53"].ToString(); 
          or1.Parameters.Add("APNLTIMEB54", OracleType.NVarChar).Value = dwData["APNLTIMEB54"].ToString(); 
          or1.Parameters.Add("APNBNOMA54", OracleType.NVarChar).Value = dwData["APNBNOMA54"].ToString(); 
          or1.Parameters.Add("APNLTIMEB55", OracleType.NVarChar).Value = dwData["APNLTIMEB55"].ToString(); 
          or1.Parameters.Add("APNBNOMA55", OracleType.NVarChar).Value = dwData["APNBNOMA55"].ToString(); 
          or1.Parameters.Add("APNLTIMEB56", OracleType.NVarChar).Value = dwData["APNLTIMEB56"].ToString(); 
          or1.Parameters.Add("APNBNOMA56", OracleType.NVarChar).Value = dwData["APNBNOMA56"].ToString(); 
          or1.Parameters.Add("APNLTIMEB57", OracleType.NVarChar).Value = dwData["APNLTIMEB57"].ToString(); 
          or1.Parameters.Add("APNBNOMA57", OracleType.NVarChar).Value = dwData["APNBNOMA57"].ToString(); 
          or1.Parameters.Add("APNLTIMEB58", OracleType.NVarChar).Value = dwData["APNLTIMEB58"].ToString(); 
          or1.Parameters.Add("APNBNOMA58", OracleType.NVarChar).Value = dwData["APNBNOMA58"].ToString(); 
          or1.Parameters.Add("APNLTIMEB59", OracleType.NVarChar).Value = dwData["APNLTIMEB59"].ToString(); 
          or1.Parameters.Add("APNBNOMA59", OracleType.NVarChar).Value = dwData["APNBNOMA59"].ToString(); 
          or1.Parameters.Add("APNLTIMEB60", OracleType.NVarChar).Value = dwData["APNLTIMEB60"].ToString(); 
          or1.Parameters.Add("APNBNOMA60", OracleType.NVarChar).Value = dwData["APNBNOMA60"].ToString(); 
          or1.Parameters.Add("APNLTIMEB61", OracleType.NVarChar).Value = dwData["APNLTIMEB61"].ToString(); 
          or1.Parameters.Add("APNBNOMA61", OracleType.NVarChar).Value = dwData["APNBNOMA61"].ToString(); 
          or1.Parameters.Add("APNLTIMEB62", OracleType.NVarChar).Value = dwData["APNLTIMEB62"].ToString(); 
          or1.Parameters.Add("APNBNOMA62", OracleType.NVarChar).Value = dwData["APNBNOMA62"].ToString(); 
          or1.Parameters.Add("APNLTIMEB63", OracleType.NVarChar).Value = dwData["APNLTIMEB63"].ToString(); 
          or1.Parameters.Add("APNBNOMA63", OracleType.NVarChar).Value = dwData["APNBNOMA63"].ToString(); 
          or1.Parameters.Add("APNLTIMEB64", OracleType.NVarChar).Value = dwData["APNLTIMEB64"].ToString(); 
          or1.Parameters.Add("APNBNOMA64", OracleType.NVarChar).Value = dwData["APNBNOMA64"].ToString(); 
          or1.Parameters.Add("APNLTIMEB65", OracleType.NVarChar).Value = dwData["APNLTIMEB65"].ToString(); 
          or1.Parameters.Add("APNBNOMA65", OracleType.NVarChar).Value = dwData["APNBNOMA65"].ToString(); 
          or1.Parameters.Add("APNLTIMEB66", OracleType.NVarChar).Value = dwData["APNLTIMEB66"].ToString(); 
          or1.Parameters.Add("APNBNOMA66", OracleType.NVarChar).Value = dwData["APNBNOMA66"].ToString(); 
          or1.Parameters.Add("APNLTIMEB67", OracleType.NVarChar).Value = dwData["APNLTIMEB67"].ToString(); 
          or1.Parameters.Add("APNBNOMA67", OracleType.NVarChar).Value = dwData["APNBNOMA67"].ToString(); 
          or1.Parameters.Add("APNLTIMEB68", OracleType.NVarChar).Value = dwData["APNLTIMEB68"].ToString(); 
          or1.Parameters.Add("APNBNOMA68", OracleType.NVarChar).Value = dwData["APNBNOMA68"].ToString(); 
          or1.Parameters.Add("APNLTIMEB69", OracleType.NVarChar).Value = dwData["APNLTIMEB69"].ToString(); 
          or1.Parameters.Add("APNBNOMA69", OracleType.NVarChar).Value = dwData["APNBNOMA69"].ToString(); 
          or1.Parameters.Add("APNLTIMEB70", OracleType.NVarChar).Value = dwData["APNLTIMEB70"].ToString(); 
          or1.Parameters.Add("APNBNOMA70", OracleType.NVarChar).Value = dwData["APNBNOMA70"].ToString(); 
          or1.Parameters.Add("APNLTIMEB71", OracleType.NVarChar).Value = dwData["APNLTIMEB71"].ToString(); 
          or1.Parameters.Add("APNBNOMA71", OracleType.NVarChar).Value = dwData["APNBNOMA71"].ToString(); 
          or1.Parameters.Add("APNLTIMEB72", OracleType.NVarChar).Value = dwData["APNLTIMEB72"].ToString(); 
          or1.Parameters.Add("APNBNOMA72", OracleType.NVarChar).Value = dwData["APNBNOMA72"].ToString(); 
          or1.Parameters.Add("APNLTIMEB73", OracleType.NVarChar).Value = dwData["APNLTIMEB73"].ToString(); 
          or1.Parameters.Add("APNBNOMA73", OracleType.NVarChar).Value = dwData["APNBNOMA73"].ToString(); 
          or1.Parameters.Add("APNLTIMEB74", OracleType.NVarChar).Value = dwData["APNLTIMEB74"].ToString(); 
          or1.Parameters.Add("APNBNOMA74", OracleType.NVarChar).Value = dwData["APNBNOMA74"].ToString(); 
          or1.Parameters.Add("APNLTIMEB75", OracleType.NVarChar).Value = dwData["APNLTIMEB75"].ToString(); 
          or1.Parameters.Add("APNBNOMA75", OracleType.NVarChar).Value = dwData["APNBNOMA75"].ToString(); 
          or1.Parameters.Add("APNFILLER", OracleType.NVarChar).Value = dwData["APNFILLER"].ToString(); 
                    #endregion
                    break; 
                default:
                    break;
            }


            Connect2Proxy(or1);
        }
    }
}
